<?php

namespace common\models\credit_public_tables;

use Yii;

/**
 * This is the model class for table "{{%sl_check_1022}}".
 *
 * @property integer $id
 * @property string $c_name
 * @property string $c_card
 * @property integer $c_time
 * @property string $c_source
 * @property string $perfer_back
 */
class SlCheck1022 extends \yii\db\ActiveRecord
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return '{{%sl_check_1022}}';
    }

    /**
     * @return \yii\db\Connection the database connection used by this AR class.
     */
    public static function getDb()
    {
        return Yii::$app->get('db_public');
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['c_name', 'c_card'], 'required'],
            [['c_time'], 'integer'],
            [['perfer_back'], 'string'],
            [['c_name'], 'string', 'max' => 200],
            [['c_card'], 'string', 'max' => 20],
            [['c_source'], 'string', 'max' => 10],
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'c_name' => 'C Name',
            'c_card' => 'C Card',
            'c_time' => 'C Time',
            'c_source' => 'C Source',
            'perfer_back' => 'Perfer Back',
        ];
    }
}
